package com.hxd.otc.widget;

import android.content.Context;
import android.support.annotation.Nullable;
import android.util.AttributeSet;
import android.view.View;

import com.flyco.dialog.utils.StatusBarUtils;

/**
 * Created by lzy on 2018/9/27 0027.
 * description ${状态栏View}
 */
public class StatusBarView extends View {
    public StatusBarView(Context context) {
        super(context, null);
    }

    public StatusBarView(Context context, @Nullable AttributeSet attrs) {
        super(context, attrs, 0);
    }

    public StatusBarView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
    }

    @Override
    protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
        int measureWidth = MeasureSpec.getSize(widthMeasureSpec);
        setMeasuredDimension(measureWidth, StatusBarUtils.getHeight(getContext()));
    }
}
